package com.skylink.gaea.jdbc.config;

import com.baomidou.mybatisplus.core.incrementer.IdentifierGenerator;
import com.skylink.gaea.jdbc.uid.StandaloneUidGenerator;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * @author zeno
 */
@ConditionalOnProperty(prefix = "gaea-jdbc.uid-generator",name = "disable",matchIfMissing = true,havingValue = "false")
@Configuration(proxyBeanMethods = false)
public class UidGeneratorAutoConfig{

  @Bean
  public IdentifierGenerator standaloneUidGenerator(){
    return new StandaloneUidGenerator();
  }

}
